package com.trf.dao.user;

import com.trf.pojo.User;

import java.sql.Connection;
import java.sql.SQLException;
import java.util.List;

/**
 * @author 唐荣锋
 * @Date 2022/3/9-星期三-16:47
 */
public interface UserDao {
    //得到登录的用户
    public User getLoginUser(Connection  connection, String userCode) throws SQLException;

    //修改当前用户密码，注意！增删该都是int
    public int updatePwd(Connection connection,int id,String password) throws SQLException;

    //查询用户总数
    public int getUserCount(Connection connection,String username,int userRole) throws SQLException;

    //通过条件查询-userList
    public List<User> getUserList(Connection connection,String userName,int userRole,int currentPageNo,int pageSize) throws SQLException;
}